GCC=gcc
CPPFLAGS=-Wall
CPPLINKS=-lpthread

SRC=$(wildcard *.s)
OBJ=$(patsubst %.s, %, $(SRC))

.PHONY:all clean

all: $(OBJ)

%:%.s
	@echo "link option: ${CPPLINKS}"
	$(GCC) $<  $(CPPFLAGS) -o $@ $(CPPLINKS)

clean:
	rm -rf $(OBJ)
